import 'package:flutter/material.dart';

///设置横线,只有手势用到
///设置横线
class HorizontalLine extends StatelessWidget {
  final double dashedWidth;
  final double dashedHeight;
  final Color color;
  //add by hiram
  //不同布局，间距有可能不一样
  final double dashedLeft;
  final double dashedTop;
  final double dashedRight;
  final double dashedBottom;

  HorizontalLine({
    this.dashedHeight = 1.0,
    //double.infinity最大值
    this.dashedWidth = double.infinity,
    this.color = const Color(0xFFededed),
    this.dashedLeft = 0.0,
    this.dashedTop = 0.0,
    this.dashedRight = 0.0,
    this.dashedBottom = 0.0,
  });

  @override
  Widget build(BuildContext context) {
    return Container(margin: EdgeInsets.only(left: dashedLeft, top:dashedTop, right: dashedRight, bottom: dashedBottom),width: dashedWidth, height: dashedHeight, color: color);
  }
}